<?php

namespace plugin\agent\app\admin\validate;

use app\common\validate\BaseValidate;

class AgentRuleValidate extends BaseValidate
{
    protected $rule = [
        'id' => 'require',
        'name' => 'require',
        'one_rate' => 'must',
        'two_rate' => 'must',
        'three_rate' => 'must',
    ];

    protected $field = [
        'id' => 'ID',
        'name' => '规则名称',
        'one_rate' => '一级比例',
        'two_rate' => '二级比例',
        'three_rate' => '三级比例',
    ];
    protected $scene = [
        "id" => [
            'id',
        ],
        "add" => [
            'name',
            'one_rate',
            'two_rate',
            'three_rate',
        ],
        "update" => [
            'id',
            'name',
            'one_rate',
            'two_rate',
            'three_rate',
        ],
    ];
}